//Tuesday, December 15 2009
#include <iostream>
#include <string>
#include <vector>
#include <map>
#include <queue>
#include <sstream>
#include <algorithm>

using namespace std;

class FIELDDiagrams
{
public:
	long long countDiagrams(int fieldOrder)
	{
		long long dp[50][50];
		memset(dp, -1, sizeof(dp));
		for(int i=0; i<=fieldOrder; i++)
			dp[fieldOrder][i] = 1;
		for(int i=fieldOrder-1; i>=0; i--)
		{
			for(int j=0; j<=fieldOrder; j++)
			{
				dp[i][j] = 0;
				for(int k=0; k<=min(fieldOrder-i, j); k++)
					dp[i][j] += dp[i+1][k];
			}
		}
		return dp[0][fieldOrder]-1;
	}
};
